package pers.cmc.mysql.model;

import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.ToString;

import java.sql.Connection;

/**
 * @author EDY
 */
@Data
@ToString
@EqualsAndHashCode
public class ConnectionInfo {
    private Connection connection;
    private Boolean state = true;

    public ConnectionInfo(Connection connection,Boolean state) {
        this.connection = connection;
        this.state = state;
    }

    /** 释放连接 */
    public void close(){
        this.state = true;
    }
}
